home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Treccani Italiana Di Scienze Lettere Ed Arti
/
[Enciclopedia] Treccani Italiana di scienze lettere ed arti.iso
/
pc
/
data
/
xxi_appendice_dvd.swf
/
scripts
/
__Packages
/
mx
/
remoting
/
Operation.as
< prev
next >
Wrap
Text File
|
2007-11-08
|
2KB
|
75 lines
class mx.remoting.Operation
{
function Operation(methodName, parent)
{
this.__service = parent;
this.__responder = parent.responder;
this.__methodName = methodName;
this.__invokationName = this.__service.__get__name() + "." + methodName;
this.__request = new Object();
this.__arguments = new Array();
}
function createThenSend(Void)
{
this.createArguments();
return this.send();
}
function send(Void)
{
this.__service.log.logInfo("Invoking " + this.__methodName + " on " + this.__service.__get__name());
var _loc3_ = new mx.remoting.PendingCall(this.__service,this.__methodName);
_loc3_.__set__responder(this.__responder);
var _loc2_ = null;
if(this.__arguments == null)
{
_loc2_ = new Array();
}
else
{
_loc2_ = this.__arguments.concat();
}
this.__invokationName = this.__service.__get__name() + "." + this.__methodName;
_loc2_.unshift(this.__invokationName,_loc3_);
this.__service.__get__connection().call.apply(this.__service.__get__connection(),_loc2_);
return _loc3_;
}
function invoke(a)
{
this.__arguments = a;
}
function get responder()
{
return this.__responder;
}
function set responder(r)
{
this.__responder = r;
}
function get request()
{
return this.__request;
}
function set request(r)
{
this.__request = r;
}
function get name()
{
return this.__methodName;
}
function createArguments()
{
if(this.__request != null)
{
this.__arguments = new Array();
for(var _loc2_ in this.__request)
{
if(_loc2_ != "arguments")
{
this.__arguments.unshift(this.__request[_loc2_]);
}
}
}
}
}